package org.jeecg.modules.mes.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.jeecg.modules.mes.entity.MesSalaryCalculationRecord;

import java.util.Date;
import java.util.List;

/**
 * @Description: 薪资计算记录表
 * @Author: jeecg-boot
 * @Date: 2025-09-03
 * @Version: V1.0
 */
@Mapper
public interface MesSalaryCalculationRecordMapper extends BaseMapper<MesSalaryCalculationRecord> {

    /**
     * 根据员工ID和日期范围查询薪资记录
     */
    List<MesSalaryCalculationRecord> selectByEmployeeAndDateRange(
            @Param("employeeId") String employeeId,
            @Param("startDate") Date startDate,
            @Param("endDate") Date endDate
    );

    /**
     * 根据任务ID查询薪资记录
     */
    List<MesSalaryCalculationRecord> selectByTaskId(@Param("taskId") String taskId);

    /**
     * 根据参与者ID查询薪资记录
     */
    List<MesSalaryCalculationRecord> selectByParticipantId(@Param("participantId") String participantId);
}
